<?php

use yii\helpers\Html;
use yii\grid\GridView;

/* @var $this yii\web\View */
/* @var $searchModel app\modules\admin\models\PaymentmemberSearch */
/* @var $dataProvider yii\data\ActiveDataProvider */

$this->title = '支付即会员';
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="paymentmember-index">

    <h1><?= Html::encode($this->title) ?></h1>
    <?php // echo $this->render('_search', ['model' => $searchModel]); ?>

    <p>
        <?= Html::a('设置会员激活规则', ['create'], ['class' => 'btn btn-success']) ?>
    </p>

    <?= GridView::widget([
        'dataProvider' => $dataProvider,
        'filterModel' => $searchModel,
        'columns' => [
            ['class' => 'yii\grid\SerialColumn'],
            'id',
            'identifier_id',
            'mchid_list',
            'card_id',
            'least_cost',
            'max_cost',
            'jump_url:url',
            'rule_id',
            'begin_time:datetime',
            'end_time:datetime',
            // ['class' => 'yii\grid\ActionColumn'],
            [
                'class' => 'yii\grid\ActionColumn',
                'header'=>'操作',
                'template' => '{view}{delete}',
                // 'buttons' => [
                //     'delete' => function ($url, $model, $key) {
                //         return  Html::a('<span class="	glyphicon glyphicon-zoom-in"></span>', $url, ['title' => '删除'] ) ;
                //     },
                // ],
            ],
        ],
    ]); ?>
</div>
